<template>
  <div>父级</div>
  <div>子组件传父组件的值： {{nameStr.name}}</div>
  <br/>
  <!-- <wwaterFallVue :title="name"></wwaterFallVue> -->
  <waterFallVue ref="waterFallVue" @on-click="getName"></waterFallVue>
</template>

<script setup lang="ts">
import { ref, reactive } from "vue"
import waterFallVue from "./components/water-fall02.vue"

const waterFall = ref<InstanceType<typeof waterFallVue>>()
const nameStr = ref({name: "暂无"})


const getName = (name:string) => {
  console.log(name)
  nameStr.value.name = name
}


// waterFall.value?.name
waterFall.value?.open()
</script>

<style lang="scss">
  
</style>